/* Moment - 1
 * Create a function that takes numbers as parameters
 * and returns the mean of the 4 numbers.
 */
function Mean(n1, n2, n3, n4)
{
	var total = n1+n2+n3+n4;
	
	total /= 4;
	
	document.getElementById("mean").innerHTML="Medelvärdet = " + total;
	
	return total;
}



/* Moment 2
 * Create a function that takes a number of arguments 
 * and then writes the arguments to the HTML-document
 * separated by ,
 */
function WriteArgumentsToHTML(arg1, arg2, arg3)
{
	// Create a string containing the text from all the arguments.
	var text = arg1 + ", " + arg2 + ", " + arg3;
	
	// Write the string to the element by the id "text".
	document.getElementById("text").innerHTML=text;
}